using System.Collections;
using System.Collections.Generic;
using UnityEngine;

namespace PlatformShoot {
    public class CameraCtrl : MonoBehaviour
    {
        private Transform _target;
        private Vector3 nowCam;
        public float CamSensitivity = 5f;
        private void Start()
        {
            _target = GameObject.FindGameObjectWithTag("Player").transform;
        }
        private void LateUpdate()
        {
            nowCam = transform.position;
            transform.position = Vector3.Lerp(nowCam,_target.position, CamSensitivity * Time.deltaTime);
        }
    }
}
